<script src="__TMPL__/libs/jquery.min.js"></script>
<script src="__TMPL__/libs/bootstrap/bootstrap.min.js"></script>
<script src="__TMPL__/common/common.js"></script>
<script src="__TMPL__/common/slippry.min.js"></script>
<script src="__STATIC__/js/wind.js"></script>
    <script src="__STATIC__/js/frontend.js"></script>
<script>
	$(function(){
		$("#nav a").each(function() {
			if ($(this)[0].href == String(window.location)) {
				$(this).addClass("selected");
			}
		});
        ;(function($){
			$.fn.totop=function(opt){
				var scrolling=false;
				return this.each(function(){
					var $this=$(this);
					$(window).scroll(function(){
						if(!scrolling){
							var sd=$(window).scrollTop();
							if(sd>100){
								$this.fadeIn();
							}else{
								$this.fadeOut();
							}
						}
					});
					
					$this.click(function(){
						scrolling=true;
						$('html, body').animate({
							scrollTop : 0
						}, 500,function(){
							scrolling=false;
							$this.fadeOut();
						});
					});
				});
			};
		})(jQuery); 
		$("#backtotop").totop();		
	});
    $(function () {
        $("#home-slider").slippry({
            transition: 'fade',
            useCSS: true,
            captions: false,
            speed: 1000,
            pause: 3000,
            auto: true,
            preload: 'visible'
        });
        $("#home-slider").show();
    });
	</script>